package com.bsoft.gol.hcb.dao.prescriptionCirculation;

import ctd.persistence.annotation.DAOMethod;
import ctd.persistence.annotation.DAOParam;
import ctd.persistence.support.hibernate.HibernateSupportDelegateDAO;
import ctd.spring.boot.annotation.SsdevDao;
import ctd.util.annotation.RpcService;
import pcn.prescribe.OdsExpressInfo;

/**
 * @Author zhusm@bsoft.com
 * @Description 订单表Dao
 * @Date 2019/12/26
 */
@SsdevDao(serviceId = "odsExpressInfoDAOService")
public abstract class OdsExpressInfoDAO extends HibernateSupportDelegateDAO<OdsExpressInfo> {
    public OdsExpressInfoDAO() {
        this.setKeyField("expressInfoId");
    }

    @RpcService
    @DAOMethod(sql = "from OdsExpressInfo where orderId =:orderId")
    public abstract OdsExpressInfo getOdsExpressInfo(@DAOParam("orderId")String orderId);

    @RpcService
    public OdsExpressInfo saveOdsExpressInfo(OdsExpressInfo odsExpressInfo){
        return this.save(odsExpressInfo);
    }
}
